'use strict';
const uniID = require('uni-id-common')
const ASE= require('ase')
exports.main = async (event, context) => {
	const uniIDIns = uniID.createInstance({
		context: context,
	})
	const res = await uniIDIns.checkToken(event.uniIdToken)
	const db = uniCloud.databaseForJQL({
			event,
			context 
		});
	const info=await db.collection("item").where({_id:event._id,user_id:res.uid}).get();
	return ASE.AES.encrypt(JSON.stringify({msg:"获取成功",data:info.data}),'yclycl1314520520','9740022097400220')
};
